from django.template import Library

register = Library()


@register.simple_tag
def cla_space(size):
    if size > 1024:
        return f'{round(size/1024,2)}G'
    return f'{size}M'
